var mongoose = require('mongoose');
require('./model/usersModel.js');
require('./model/adminModel.js');
require('./model/commentModel.js');
require('./model/goodsModel.js');
require('./model/orderModel.js');
require('./model/outletModel.js');
require('./model/serviceModel.js');
require('./model/supGoodsModel.js');
require('./model/supplierModel.js');
require('./model/supplyOrder');

//建立数据库连接
mongoose.connect('mongodb://localhost/lps', {
    useUnifiedTopology: true,
    useNewUrlParser: true
});
mongoose.connection.on('connected', function () {
    console.log('Mongoose connected to mongodb://localhost/lps');
});

